export const SET_GROUPBUY = 'SET_GROUPBUY' //获取团购列表
export const PUSH_GROUPBUY = 'PUSH_GROUPBUY' //发起团购加入团购列表
export const ADD_GROUPBUY = 'ADD_GROUPBUY' //参与团购加入团购列表


export default{
    state:{},
    mutations: {

        [SET_GROUPBUY](state, data) {
            state.content = data;
        },
        [PUSH_GROUPBUY](state, data) {
            state.content.push(data);
        },
        [ADD_GROUPBUY](state, obj) {
        },
    },
    actions: {
        [SET_GROUPBUY]({commit}, data){
            commit(SET_GROUPBUY, data)
        },
        [PUSH_GROUPBUY]({commit}, data){
            commit(PUSH_GROUPBUY, data)
        },
        [ADD_GROUPBUY]({commit}, obj){
            commit(ADD_GROUPBUY, obj)
        }
    }
}